package com.mutual.assistance.user.model.vo;

import com.mutual.assistance.validation.ValidationGroups;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

@Data
@ApiModel(value="上传菜单资源", description="上传菜单资源")
public class AddMenuVO implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "菜单编码，例如：test")
    @NotBlank(message = "菜单编码不能为空", groups = ValidationGroups.Insert.class)
    private String code;

    @ApiModelProperty(value = "父菜单ID")
    @NotBlank(message = "父菜单id不能为空",groups = ValidationGroups.Insert.class )
    private String pId;

    @ApiModelProperty(value = "名称")
    @NotBlank(message = "菜单名称不能为空，例如：添加测试", groups = ValidationGroups.Insert.class)
    private String menuName;

    @ApiModelProperty(value = "请求地址")
    private String url;

    @ApiModelProperty(value = "是否是菜单")
    @NotNull(message = "菜单标识不能为空", groups = ValidationGroups.Insert.class)
    private Boolean isMenu;

}
